package com.ming_za.odupdaterserver.core.utils;

import org.springframework.web.client.RestTemplate;

public class NetworkUtils {

    private static final RestTemplate restTemplate = new RestTemplate();

    public static boolean notLocalHost(String host) {
        return !host.equals("localhost") && !host.equals("127.0.0.1") && !host.equals("0:0:0:0:0:0:0:1");
    }

    public static<T> T sendGet(String url,Class<T> c){
        return restTemplate.getForObject(url,c);
    }

}
